home *** CD-ROM | disk | FTP | other *** search
/ Mac Mania 6 / MacMania 6.toast / / Tools&Utilities / TouchMe 1.2□ / touchMe 1.2 Folder / touchMe source codes / CW11 PP source / source / touchMeReadme.cp < prev    next >
Encoding:
Text File  |  1997-04-25  |  19.1 KB  |  528 lines  |  [TEXT/CWIE]

  1. // ==================================================
  2. //    touchMeReadme.cp
  3. //    Copyright (C) 1994-1997 Mizutori Tetsuya
  4. //    v.1.0        March 9, 1994 written in THINK-C
  5. //    v.1.1        July 4 ,1996 written in CodeWarrior 9
  6. //    v.1.1.1    August 4, 1996 written in CodeWarrior 9
  7. //    v.1.1.2    February 3, 1997 written in CodeWarrior 11
  8. //    v.1.2        April 25, 1997 written in CodeWarrior 11
  9. // ==================================================
  10. //    All documents are pretty-printed in 10-point Geneva font.
  11.  
  12. #ifdef COMMENT
  13.  
  14. // This summary of functions are made with 'HeaderSampler.pl'.
  15.  
  16. Symbol Table for member functions or variables:
  17. =s=    public: static
  18. =v=    public: virtual
  19. =.=    public:
  20. >s>    protected: static
  21. >v>    protected: virtual
  22. >.>    protected:
  23. (s)    private: static
  24. (v)    private: virtual
  25. (.)    private:
  26.  
  27.  
  28. // --------------------------------------------------
  29. //    CTouchMe Program Roadmap
  30. // --------------------------------------------------
  31.  
  32. // --------------------------------------------------
  33.  
  34. CTouchMeApp
  35.  * superclass: LDocApplication
  36.  * function:
  37. =.=    CTouchMeApp            ()
  38. =v=    ~CTouchMeApp            ()
  39.  
  40. =v=    ObeyCommand            Boolean(CommandT, void *)
  41. =v=    FindCommandStatus        void(CommandT, Boolean &, Boolean &, Char16 &, Str255)
  42.         // Execute once when launched by receiving Finder's OpenApplication event
  43. >v>    StartUp                void()
  44.         // Execute every time whenever OpenDocument AppleEvent was received
  45.         // Do touch command, or fill date time stamp field if option-key is pressed
  46. >v>    OpenDocument            void(FSSpec *)
  47. >v>    ChooseDocument            void()
  48.         // Reset the working status every time when a series of execution has finished
  49. >v>    UseIdleTime            void(const EventRecord &)
  50.         // Override the procedure to make a patch for displaying "About..." dialog
  51. >v>    ShowAboutBox            void()
  52.         // Application-spicific functions
  53. >.>    MakeMainWindow        LWindow *()
  54. >.>    HandleDocuments        void()
  55.  
  56.         // My AppleEvent handlers for 'HandleXXX()' functions
  57. >v>    HandleAppleEvent        void(const AppleEvent &, AppleEvent &, AEDesc &, Int32)
  58.         // For responding AppleScript commands;
  59.         // 'get prefs', 'set prefs', 'load prefs', 'save prefs', 'touch', 'fetch'
  60. >.>    HandleGetPrefs            void(const AppleEvent, AppleEvent &, AEDesc &)
  61. >.>    HandleSetPrefs            void(const AppleEvent, AppleEvent &, AEDesc &)
  62. >.>    HandleLoadPrefs            void(const AppleEvent, AppleEvent &, AEDesc &)
  63. >.>    HandleSavePrefs            void(const AppleEvent, AppleEvent &, AEDesc &)
  64. >.>    HandleTouch            void(const AppleEvent, AppleEvent &, AEDesc &)
  65. >.>    HandleFetch            void(const AppleEvent, AppleEvent &, AEDesc &)
  66. >.>    HandleGetPrefsSettings    void(AERecord &, ETouchType, Boolean)
  67. >.>    HandleSetPrefsSettings    void(AERecord &, ETouchType)
  68. >.>    HandleFetchDateTime        void(AERecord &, FSSpec &, Boolean)
  69.  
  70.  * variable:
  71. >s>    MyAlertPatch            pascal Boolean(DialogRef, EventRecord *, short *)
  72. (.)    LWindow *                mMainWindow        // Instance object of class 'CTouchMeMainWindow'
  73. (.)    LArray *                mFileArray        // Instance object of file stack array
  74. (.)    CTouchMePref *            mPref            // Instance object of class 'CTouchMePref'
  75. (.)    CAppleGuideFile *        mAppleGuideFile        // Instance object of Apple Guide file
  76.  
  77. (s)    ModalFilterUPP            sAlertPatchProc        // A patch for displaying colored alert dialog
  78.  
  79. (.)    Boolean                mOpenApplication    // true if launched by the OpenApplication event
  80. (.)    Boolean                mOpenDocument        // true if invoked by the OpenDocument event
  81. (.)    Boolean                mKeyModifier        // Check the modifier key if pressed on "Open..." command
  82. (.)    Boolean                mUpdatePref        // true if settings must be reset by prefs data
  83. (.)    long                    mCount            // A counter of execution times in the series of document files
  84. (.)    Boolean                mIsCommandPeriod    // true if cmd-period key is pressed
  85.  
  86.  * resource:
  87.     touchMeAppleEvents.r                        // Resource definition for AppleEvent 'aedt' and 'aete'
  88.     touchMeVersion.r                        // Version resource
  89.  
  90. // --------------------------------------------------
  91.  
  92. CTouchMeMainWindow
  93.  * superclass: LDialogBox, LBroadcaster, LDragAndDrop
  94.  * function:
  95. =s=    CreateTouchMeMainWindowStream    CTouchMeMainWindow *(LStream)
  96. =.=    CTouchMeMainWindow        (LStream)
  97. =.=    ~CTouchMeMainWindow    ()
  98.  
  99. =v=    FindCommandStatus        void(CommandT, Boolean, Boolean, Char16, Str255)
  100.         // Control the synchronous RadioButton changes
  101.         // Control the 'Current Date Time Now!' button, and others
  102. =v=    ListenToMessage            void(MessageT, void)
  103.         // Set and Get dialog status according to the 'CTouchMePref' instance data
  104.         // Get the global frame rect, a bound of dialog
  105. =.=    GetGlobalFrameRect        void(Rect &)
  106.         // Move the dialog window
  107. =.=    MoveWindow            void(Rect &)
  108.         // Setup dialog status according to the 'pref' data
  109. =.=    SetupDialog            void(const SPrefsRec &)
  110.         // Set the 'pref' data according to the dialog status
  111. =.=    InspectDialog            void(SPrefsRec &)
  112.         // Show an indiactor whether the modifier key is pressed
  113. =.=    Indicator                void(const Boolean)
  114.         // for Dialog
  115.         // Add listeners of RadioButtons to broadcaster of LStdCheckBox
  116. >v>    FinishCreateSelf            void()
  117.         // Draw my additional figures in the dialog window
  118. >v>    DrawSelf                void()
  119.         // Quit program like as "Cancel" button if "Close Box" was selected
  120. >v>    AttemptClose            void()
  121.  
  122.         // for Dialog
  123. (.)    SetEditFieldText            void(PaneIDT, const Str255, Boolean)
  124. (.)    SetEditFieldTextRefresh    void(PaneIDT, const Str255, Boolean)
  125. (.)    GetEditFieldText            void(PaneIDT, Str255, Boolean)
  126. (.)    SetEditFieldDateTime        void(PaneIDT, const unsigned long, Boolean)
  127. (.)    GetPairedPaneID            PaneIDT(const PaneIDT)
  128.  
  129.         // for Dialog
  130.         // Drag&Drop; accept files or folders dropped from Finder
  131. >v>    ItemIsAcceptable            Boolean(DragReference, ItemReference)
  132.         // Drag&Drop; retrieve the FSSpec from the dropped object
  133.         // Set the date time stamp fields according to the accepted file
  134.         // Or do touch command if option-key is pressed
  135. >v>    ReceiveDragItem            void(DragReference, DragAttributes, ItemReference, Rect)
  136.         // Drag&Drop; execute once if entered into the area
  137. >v>    EnterDropArea            void(DragReference, Boolean)
  138.         // Drag&Drop; execute once if left from the area
  139. >v>    LeaveDropArea            void(DragReference)
  140.         // Drag&Drop; execute while staying in the area
  141. >v>    InsideDropArea            void(DragReference)
  142.         // Drag&Drop; assign my custum hilite region of EditFields
  143. >v>    HiliteDropArea            void(DragReference)
  144.         // for Drag and Drop
  145. (.)    IsModifierKeyPressed        Boolean(DragReference)
  146. (.)    FindPaneByMouse        PaneIDT(const Point)
  147. (.)    HilitePane                void(const PaneIDT)
  148. (.)    HiliteRect                void(const Rect &)
  149.  
  150.  * variable:
  151. (.)    Boolean                mGlobalModifier
  152.  
  153.         // for Drag and Drop
  154. (.)    Boolean                mTEActive
  155. (.)    Boolean                mModifier
  156. (.)    Boolean                mTextDrag
  157. (.)    PaneIDT                mHilitePaneID
  158. (.)    PaneIDT                mTargetID
  159. (.)    LCommander *            mTarget
  160.  
  161. // --------------------------------------------------
  162.  
  163. CTouchMePref
  164.  * superclass: CPrefsFile
  165.  * function:
  166. =.=    CTouchMePref            ()
  167. =.=    CTouchMePref            (ConstStr255Param)
  168. =v=    ~CTouchMePref            ()
  169.  
  170.         // Load prefs data from the Preferences file.
  171. =.=    LoadPrefsData            OSErr()
  172.         // Save prefs data to the Preferences file.
  173. =.=    SavePrefsData            OSErr()
  174.         // Set the window's settings by prefs data.
  175. =.=    SetPrefsToWindow        void(LWindow *)
  176.         // Get the window's settings to prefs data.
  177. =.=    GetPrefsFromWindow        void(LWindow *)
  178.  
  179.         // Set and Get the settings data of the member 'XXX'
  180. =.=    SetWindowRect            void(Rect &)
  181. =.=    GetWindowRect            void(Rect &)
  182. =.=    SetSync                void(const Boolean)
  183. =.=    GetSync                Boolean()
  184. =.=    SetEnabled                void(const ETouchType, const Boolean)
  185. =.=    GetEnabled                Boolean(const ETouchType)
  186. =.=    SetFlag                void(const ETouchType, const ETouchFlag, const Boolean)
  187. =.=    GetFlag                Boolean(const ETouchType, const ETouchFlag)
  188. =.=    SetFlagNumb            void(const ETouchType, const ETouchFlag)
  189. =.=    GetFlagNumb            ETouchFlag(const ETouchType)
  190. =.=    SetDateTime            void(const ETouchType, const unsigned long)
  191. =.=    GetDateTime            unsigned long(const ETouchType)
  192. (.)    SetupConstants            void()
  193.         // Transform preferences data to/from 'mPrefs' record.
  194. (.)    TransformToSettings        void()
  195. (.)    TransformFromSettings    void()
  196.  
  197.  * variable:
  198. (.)    SPrefsRec                mPrefs            // A working data structure for handling preferences file
  199.  
  200. // --------------------------------------------------
  201. //    Common Utilities
  202. // --------------------------------------------------
  203.  
  204. CAppleGuideFile
  205.  * superclass:
  206.  * function:
  207. =.=    CAppleGuideFile            (OSType)
  208. =.=    CAppleGuideFile            (ConstStr255Param)
  209. =v=    ~CAppleGuideFile        ()
  210.  
  211.         // Check if Apple Guide is installed or not.
  212. =s=    AppleGuideIsPresent        Boolean()
  213.         // Open the specified guide file located in the application's folder.
  214. =v=    Open                    AGErr()
  215.         // Find a default guide file in the same folder where the application is located.
  216.         //    OSErr            FindGuideFile( void );
  217. >.>    FindGuideFile            OSErr(ConstStr255Param)
  218. >.>    FindGuideFile            OSErr(OSType)
  219.  
  220.  * variable:
  221. (.)    Str63                mGuideFilename        // A particular Apple Guide file name
  222. (.)    Boolean                mGotGuideFile        // true if mGuideFile is valid.
  223. (.)    FSSpec                mGuideFileFSSpec    // A file spec of the guide file.
  224. (.)    OSType                mGuideCreatorType    // An application creator type.
  225. (.)    AGRefNum                mGuideFileRefNum    // A reference number of opened guide file.
  226.  
  227. // --------------------------------------------------
  228.  
  229. CDateEditField
  230.  * superclass: LEditField, LListener, LBroadcaster
  231.  * function:
  232. =s=    CreateDateEditFieldStream    CDateEditField *(LStream)
  233. =.=    CDateEditField            ()
  234. =.=    CDateEditField            (const CDateEditField)
  235. =.=    CDateEditField            (const SPaneInfo, Str255, ResIDT, Int16, Boolean, Boolean, KeyFilterFunc, LCommander)
  236. =.=    CDateEditField            (const SPaneInfo, Str255, ResIDT, Int16, Uint8, KeyFilterFunc, LCommander)
  237. =.=    CDateEditField            (LStream)
  238. =v=    ~CDateEditField            ()
  239.  
  240.         // Do nothing here
  241. =v=    ListenToMessage            void(MessageT, void *)
  242.         // Set 'mHasChanged' to true if text has been changed
  243. =v=    UserChangedText            void()
  244.         // Do dragging text
  245. =v=    ClickSelf                void(const SMouseDownEvent &)
  246.         // Do nothing here
  247. =v=    BeTarget                void()
  248.         // Call RefreshEditField() once when this EditField becomes no target
  249. =v=    DontBeTarget            void()
  250.         // Handle dragging text in this edit field.
  251. =.=    DoDragText            Boolean(const EventRecord, const Point)
  252.  
  253.         // Test / Set the activity status of TextEdit
  254. =.=    GetTEActive            Boolean()
  255. =.=    SetTEActive            void(const Boolean)
  256.         // Get / Set the selection of TextEdit
  257. =.=    GetSelect                void(long &, long &)
  258. =.=    SetSelect                void(const long, const long)
  259.         // Read / Write  the text string from this EditField
  260. =.=    GetText                void(Str255)
  261. =.=    SetText                void(const Str255)
  262.         // Write text string, and then refresh it
  263. =.=    SetTextAndRefresh        void(const Str255)
  264.         // Convert date time seconds to string, and write it
  265. =.=    SetDateTime            void(const unsigned long)
  266.         // Refresh the EditField if this text has been changed
  267. =.=    RefreshEditField            void()
  268.  
  269.  * variable:
  270. (.)    Boolean                mHasChanged        // true if text has been changed by user's action
  271.  
  272. // --------------------------------------------------
  273.  
  274. CFlavor
  275.  * superclass: none
  276.  * function:
  277. =.=    CFlavor                ()
  278. =.=    CFlavor                (DragReference, ItemReference)
  279. =.=    ~CFlavor                ()
  280.  
  281.         // Retrieve data from a drag reference
  282. (.)    GetFlavorText            OSErr(DragReference, ItemReference, Handle, Size &)
  283. (.)    GetFlavorPString        OSErr(DragReference, ItemReference, Str255)
  284. (.)    GetFlavorHFS            OSErr(DragReference, ItemReference, HFSFlavor &)
  285. (.)    GetFlavorFSSpec            OSErr(DragReference, ItemReference, FSSpec &)
  286.  
  287.  * variable:
  288. =.=    FlavorType                mType
  289. =.=    Handle                mTextH
  290. =.=    long                    mTextLen
  291. =.=    FSSpec                mFSSpec
  292.  
  293. // --------------------------------------------------
  294.  
  295. CPrefsFile
  296.  * superclass: LPreferencesFile
  297.   * function:
  298. =.=    CPrefsFile                ()
  299. =.=    CPrefsFile                (ConstStr255Param, OSType)
  300. =v=    ~CPrefsFile            ()
  301.  
  302.         // Setup constants at startup.
  303. >.>    SetupConstants            void()
  304. >.>    SetupFileInfo            void(OSType, OSType)
  305. >.>    SetupResType            void(ResType, ResIDT)
  306.  
  307.         // Read a block data from the preferences file
  308. >.>    LoadPrefs                OSErr(long &, Handle)
  309. >.>    LoadPrefs                OSErr(long &, Handle, ResType, ResIDT)
  310.         // Write a block data to the preferences file
  311. >.>    SavePrefs                OSErr(long, Handle)
  312. >.>    SavePrefs                OSErr(long, Handle, ResType, ResIDT)
  313.  
  314.  * variable:
  315. (.)    OSType                mPrefFileType        // 'pref'
  316. (.)    OSType                mPrefFileCreator    // 'MzTm'
  317. (.)    ResType                mPrefResType        // 'PREF'
  318. (.)    ResIDT                mPrefResID        // 1000
  319.  
  320. // --------------------------------------------------
  321.  
  322. CRadioButton
  323.  * superclass: LStdRadioButton, LListener
  324.  * function:
  325. =s=    CreateRadioButtonStream    CRadioButton *(LStream *)
  326. =.=    CRadioButton            ()
  327. =.=    CRadioButton            (const CRadioButton)
  328. =.=    CRadioButton            (const SPaneInfo, MessageT, Int32, ResIDT, Str255)
  329. =.=    CRadioButton            (LStream *)
  330. =v=    ~CRadioButton            ()
  331.  
  332.         // Listen to CheckBox and change its Enable/Disable status
  333. =v=    ListenToMessage            void(MessageT, void *)
  334.  
  335. // --------------------------------------------------
  336.  
  337. UAppleEvents
  338.  * superclass: none
  339.  * function:
  340. =.=    UAppleEvents            ()
  341. =.=    ~UAppleEvents            ()
  342.  
  343.         // Handling descriptor.
  344. =s=    TheLongDateTime        void(const AEDesc &, LongDateTime &)
  345. =s=    TheText                void(const AEDesc &, Handle &, long &)
  346. =s=    TheFSSpec                void(const AEDesc &, FSSpec &)
  347.  
  348.         // Handling Apple Event.
  349. =s=    GetParamLongDateTime    Boolean(const AppleEvent &, AEKeyword, LongDateTime &, const unsigned long)
  350. =s=    GetParamLong            Boolean(const AppleEvent &, AEKeyword, long &, const long)
  351. =s=    GetParamEnum            Boolean(const AppleEvent &, AEKeyword, OSType &, const OSType)
  352. =s=    GetParamBoolean        Boolean(const AppleEvent &, AEKeyword, Boolean &, const Boolean)
  353. =s=    GetParamPString        Boolean(const AppleEvent &, AEKeyword, Str255, const StringPtr)
  354. =s=    GetParamText            Boolean(const AppleEvent &, AEKeyword, Handle, long &)
  355. =s=    PutParamText            void(AppleEvent &, AEKeyword, Handle, long)
  356. =s=    PutParamFSSpec            void(AppleEvent &, AEKeyword, const FSSpec &)
  357. =s=    AddFSSpec                void(AEDescList &, long, const FSSpec &)
  358. =s=    PutParamFullPathname    void(AppleEvent &, AEKeyword, ConstStr255Param)
  359. =s=    AddFullPathname            void(AEDescList &, long, ConstStr255Param)
  360.  
  361. * variable:
  362.  
  363. // --------------------------------------------------
  364.  
  365. UDateTime
  366.  * superclass: none
  367.  * function:
  368.         // Convert date time data in 32-bit-lengh seconds to string
  369. =s=    SecondsToDateTimeString    void(const unsigned long, Str255, Str255)
  370.         // Convert date time data in 32-bit-lengh seconds from string
  371. =s=    DateTimeStringToSeconds    void(const Str255, const Str255, unsigned long &)
  372. (s)    SecondsToDateTime        void(const unsigned long, LongDateRec &)
  373. (s)    DateTimeToSeconds        void(const LongDateRec &, unsigned long &)
  374. (s)    DateTimeToString        void(const LongDateRec &, Str255, Str255)
  375. (s)    StringToDateTime        void(const Str255, const Str255, LongDateRec &)
  376.  
  377. * variable:
  378.  
  379. // --------------------------------------------------
  380.  
  381. UDragDropSuit
  382.  * superclass: none
  383.  * function:
  384. =s=    DragText                Boolean(const EventRecord &, RgnHandle, unsigned char *, long &, Boolean &)
  385. =s=    InDragRegion            Boolean(DragReference)
  386. =s=    ZoomBackBounds            void(DragReference, ItemReference)
  387. (s)    MyTrackDrag            Boolean(DragReference, const EventRecord &, RgnHandle)
  388. (s)    DropLocationIsFinderTrash    Boolean(AEDesc &)
  389.  
  390.  * variable:
  391. =s=    RgnHandle                sDragRegion
  392.  
  393. // --------------------------------------------------
  394.  
  395. UErrorMessage
  396.  * superclass: none
  397.  * function:
  398.         // Notify error message using Alert/Stop dialog
  399. =s=    NofityIfOSErr            void(const OSErr, const Boolean)
  400. =s=    NofityIfOSErr            void(const OSErr, const Str255, const Boolean)
  401.  
  402. * variable:
  403.  
  404.  * resource:
  405.     ErrorMessage.r                // Resource definition for error messages and alert dialog
  406.  
  407. // --------------------------------------------------
  408.  
  409. UFileTools
  410.  * superclass: none
  411.  * function:
  412. =.=    UFileTools                ()
  413. =.=    ~UFileTools            ()
  414.  
  415.         // Get the creation/modification date time of the given FSSpec
  416. =s=    GetFSSpecDateTime        OSErr(FSSpec &, unsigned long &, unsigned long &)
  417.         // Set the creation/modification date time of the given FSSpec
  418. =s=    SetFSSpecDateTime        OSErr(FSSpec &, unsigned long, unsigned long)
  419.  
  420. (s)    GetFileDateTime            OSErr(FSSpec &, unsigned long &, unsigned long &)
  421. (s)    SetFileDateTime            OSErr(FSSpec &, unsigned long, unsigned long)
  422. (s)    GetFolderDateTime        OSErr(FSSpec &, unsigned long &, unsigned long &)
  423. (s)    SetFolderDateTime        OSErr(FSSpec &, unsigned long, unsigned long)
  424.  
  425.         // Update the finder's folder status
  426. =s=    TouchDir                OSErr(short, long)
  427.         // Test the file type of a particular file
  428. =s=    GetFSSpecType            EFileType(FSSpec &)
  429. =s=    QueryFile                OSErr(FSSpec &, EFileType &, long &)
  430.         // Search a particure directory for the files in it.
  431.         // begins with one.
  432. =s=    SearchDirectory            OSErr(long, FSSpec &, FSSpec &, EFileType &)
  433.         // begins with one.
  434. =s=    SearchDirectory            OSErr(long, short, long, FSSpec &, EFileType &)
  435.         // Get the full pathname of a particular file.
  436. =s=    GetFullPathname            OSErr(const FSSpec &, Str255, Boolean)
  437.         // Get the file spec of the current application process.
  438. =s=    GetCurrentApplicationFile    OSErr(FSSpec &)
  439.  
  440. =s=    PStrCopy                void(Str255, const Str255)
  441. =s=    PStrCopy                void(Str255, const unsigned char *, const long)
  442. =s=    PStrAppend            void(Str255, const Str255)
  443. =s=    PStrAppend            void(Str255, const unsigned char *, const long)
  444.  
  445. * variable:
  446.  
  447. // --------------------------------------------------
  448.  
  449. UFinderEvents
  450.  * superclass:
  451.  * function:
  452.  =.=    UFinderEvents            ()
  453. =.=    ~UFinderEvents            ()
  454.  
  455.         // Send a 'Open Selection with File' event to the Finder.
  456. =s=    OpenSelection            void(const FSSpec &)
  457. =s=    OpenSelection            void(ConstStr255Param)
  458.         // Send a 'GetInfo Selection with File' event to the Finder.
  459. =s=    GetInfoSelection            void(const FSSpec &)
  460. =s=    GetInfoSelection            void(ConstStr255Param)
  461.  
  462.         // Send a 'XXXX Selection for File' event to the Finder.
  463. >s>    SendAEWithSelectionToFinder    void(AEEventID, const FSSpec &)
  464. >s>    SendAEWithSelectionToFinder    void(AEEventID, ConstStr255Param)
  465.         // Create an inAEEventID event to be sent to Finder.
  466. >s>    CreateAppleEventForFinder    void(AppleEvent &, AEEventID)
  467.         // Put the directory info of file or pathname to the event as a direct parameter.
  468. >s>    PutParamContainer        void(AppleEvent &, const FSSpec &)
  469. >s>    PutParamContainer        void(AppleEvent &, ConstStr255Param)
  470.         // Add a selection of file[s] or pathname[s]  as an "items" parameter.
  471. >s>    PutParamItems            void(AppleEvent &, const FSSpec &)
  472. >s>    PutParamItems            void(AppleEvent &, ConstStr255Param)
  473.  
  474. * variable:
  475.  
  476. // --------------------------------------------------
  477.  
  478. UMacOSTools
  479.  * superclass:
  480.  * function:
  481.  =.=    UMacOSTools            ()
  482. =.=    ~UMacOSTools            ()
  483.  
  484.         // Check keyboard status wheather cmd-period is pressed.
  485. =s=    IsCommandPeriod        Boolean()
  486.         // Check keyboard status wheather a modifier key is pressed.
  487. =s=    IsModifierKeyPressed        Boolean(Uint32)
  488. =s=    IsModifierKeyPressed        Boolean(const EventRecord &, Uint32)
  489.  
  490.         // Convert a four character code to a Pascal string and return a pointer to the string.
  491. =s=    FourCharCodeToPStr        StringPtr(FourCharCode, StringPtr)
  492.         // Convert an Pascal string to a four character code.
  493. =s=    PStrToFourCharCode        void(ConstStringPtr, FourCharCode &)
  494.  
  495.         // Set a Finder flag.
  496. =s=    SetFinderFlag            void(FSSpec &, Uint16, Boolean)
  497.         // Return whether a Finder flag is on or off.
  498. =s=    HasFinderFlag            Boolean(FSSpec &, Uint16)
  499.  
  500. * variable:
  501.  
  502. // --------------------------------------------------
  503.  
  504. UStandardFiles
  505.  * superclass:
  506.  * function:
  507.  =.=    UStandardFiles            ()
  508. =.=    ~UStandardFiles            ()
  509.  
  510.         // Prompts the user to select a File or Directory using a modified  Standard Get File dialog box.
  511. =s=    StandardGetFileOrDirectory    Boolean(FileFilterUPP, short, ConstSFTypeListPtr, StandardFileReply *)
  512.  
  513. >s>    FileFilter_SelectFile        pascal Boolean(CInfoPBPtr, void *)
  514. >s>    DialogHook_SelectFile        pascal short(short, DialogPtr, void *)
  515. >s>    SetSelectButtonTitle        void(ControlHandle, const Rect &, Str63)
  516.  
  517.  * variable:
  518. >s>    Str63                sCurrentName
  519. >s>    Str255                sSavedString
  520. >s>    Boolean                sCustomSelection
  521.  
  522.  * resource:
  523.     UStandardFiles.rsrc
  524.  
  525. // --------------------------------------------------
  526.  
  527. #endif // COMMENT
  528.